// import './assets/main.css'

import { createApp } from 'vue'
import App from './App.vue'
import router from './router'
import { createPinia } from 'pinia'

// Element Plus
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'

const app = createApp(App)
const pinia = createPinia()

// 移除重复的单独图标导入，通过循环注册所有图标
// 统一使用Element Plus图标的原始命名，避免自定义别名导致混淆
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)

  // 如果需要，可以在这里添加额外的图标注册逻辑
}

app.use(pinia)
app.use(router)
app.use(ElementPlus)

app.mount('#app')
